package com.njust.controller;

import com.njust.entity.Employee;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

@Controller
@RequestMapping("/databinder")
public class DataBinderController {

    @RequestMapping("/addpage")
    public String toAddPage(){
        return "quickadd.jsp";
    }

    @RequestMapping("/quickadd")
    public String quickAdd(@RequestParam("employeeInfo") Employee employee){
        System.out.println(employee);
        return "success.jsp";
    }
}
